﻿<!DOCTYPE html>

<html>
<head>
    <meta name="viewport" content="width=device-width" />
    <title>@ViewBag.Title</title>
    <script src="~/Scripts/vue.min.js"></script>
    <script src="~/Scripts/ElementUI/element-ui.js"></script>
    <link href="~/Element/element-ui.css" rel="stylesheet" />
    <link href="~/Content/nprogress.css" rel="stylesheet" />
    <script src="~/Scripts/js-cookie/js.cookie-2.2.1.min.js"></script>
    <script src="~/Scripts/axios.min.js"></script>
    <script src="~/Scripts/echarts.js"></script>
    <link href="~/Scripts/font-awesome.min.css" rel="stylesheet" />
    <script src="~/Scripts/jquery-1.8.1.min.js"></script>
    <script src="~/Scripts/nprogress.min.js"></script>
    <script src="~/Scripts/ns.hover.min.js"></script>
    <link href="~/Scripts/stylesCode.css" rel="stylesheet" />
    <script src="~/iconfont/iconfont.js"></script>
    <link href="~/iconfont/iconfont.css" rel="stylesheet" />
    <script>
        $(function () {
            NProgress.start();
            $(window).load(function () {
                NProgress.done();
            })
        });
    </script>
    <style>
        .fixed-bottom {
            position: fixed;
            bottom: 0;
            width: 100%;
        }
      
    </style>
</head>
<body>
    <div class="topclass">
        @RenderPage("Top.cshtml")
    </div>
    <div class="mainclass">
        @RenderBody()      
        @RenderPage("videoPlayer.cshtml")
    </div>
    <footer>
        @RenderPage("Footer.cshtml")
    </footer>
    <script>
        $(function () {
            $("#navi a").click(function () {
                $("#content").src = this.data("data-href");
            })
            function footerPosition() {
                $("footer").removeClass("fixed-bottom");
                //网页正文全文高度
                var contentHeight = document.body.scrollHeight,
                    //可视窗口高度，不包括浏览器顶部工具栏
                    winHeight = window.innerHeight;
                if (!(contentHeight > winHeight)) {
                    //当网页正文高度小于可视窗口高度时，为footer添加类fixed-bottom
                    $("footer").addClass("fixed-bottom");
                } else {
                    $("footer").removeClass("fixed-bottom");
                }
            }
            footerPosition();
            $(window).resize(footerPosition);
            var setConfig = {
                song: JSON.parse(localStorage.getItem('ListenMusicLists')),
                error: function (meg) {
                    console.log(meg);
                }
            };
            var audioFn = audioPlay(setConfig);
            if (audioFn) {
                audioFn.loadFile(false);
            }        
        }); 
    </script>

</body>
</html>
